<!DOCTYPE>
<html >
<head>
    <meta charset="utf-8">
    <link rel="stylesheet" href="__PUBLIC__/Home/css2.css">
    <script src="__PUBLIC__/Admin/js/jquery-1.9.1.js"></script>
    <script src="__PUBLIC__/Common/Layer/layer.js"></script>
    <title>结算页</title>
</head>
<body>


<!-- 栏目 -->
<div class="vice-bj">
    <div class="vice">
    	<span class="left">
			<if condition="empty($_SESSION['user_id'])">
			<a href="{:U('Public/login')}" class="green">亲，请登录</a>
			<a href="{:U('Public/reg')}">&#12288会员注册</a>
			<else/>
		欢迎您，{$_SESSION['mobile']}&nbsp;&nbsp;&nbsp;<a href="{:U('User/logout')}" class="green">退出登陆</a>
			</if>
        </span>
        <strong class="right vice1">
        <a href="{:U('User/my_order_lst')}">我的订单</a>
        <a href="{:U('Mobile/Index/index')}" class="Phone" style="padding-left:18px;">手机掌中游</a>
        </strong>
    </div>
</div>
<!-- 头 -->
<div class="head">
    <a href="{:U('Index/index')}"><img src="__PUBLIC__/Home/img/index/logo.png" width="198" height="94"></a>
<span>
	<b class="left green1">1.我的购物车</b>
	<b class="left green2">2.填写核对订单信息 </b>
	<b class="left">3.成功提交订单</b>
</span>
</div>
<!-- 内容 -->
<form method="post" action="{:U('Cart/order_form')}" onsubmit="return check();">
<div class="content">
    <h3 class="size14">填写并核对订单信息</h3>
    <div class="Order" style="width:1055px;">
        <h3><span class="size14 bold left">收货人信息</span><a href="javascript:void (0);" class="right basket size12" onclick="add_addr();">新增收货地址</a></h3>
        <ul class="address">
            <foreach name="res_addr" item="vo" key="k">
                <if condition="$vo['status'] eq 1">
                         <li style="overflow: hidden;  zoom: 1;" class="li_add">
                             <a href="javascript:void (0);" onclick="getCity(this)" class="hover li_a" style="float: left">{$vo.realname} {$vo.prov}</a><p style="float: left" class="li_p">{$vo.realname}<span class="addre"> {$vo.prov} {$vo.city} {$vo.dist} {$vo.address}</span><p></p>
                             <b class="default" style="float: left; margin-left:10px;">默认地址 </b><p style="float: right; color: #005EA7;"><a href="javascript:void (0);" onclick="addr_edite({$vo.id})">编辑</a> </p>
                             <input type="hidden"  class="realname1" value="{$vo.realname}"><input type="hidden"  class="mobile1" value="{$vo.mobile}">
                         </li>
                    <elseif condition="($res_ad['count'] eq 0) AND ($vo['status'] neq 1) AND $k eq 0"/>
                        <li style="overflow: hidden;  zoom: 1;" class="li_add">
                            <a href="javascript:void (0);" onclick="getCity(this)" style="float: left" class="li_a">{$vo.realname} {$vo.prov}</a><p style="float: left" class="li_p">{$vo.realname}<span class="addre"> {$vo.prov} {$vo.city} {$vo.dist} {$vo.address}</span><p></p><p style="float: right; color: #005EA7;"><a href="javascript:void (0);" onclick="addr_edite({$vo.id})">编辑</a></p>
                            <input type="hidden"  class="realname1" value="{$vo.realname}"><input type="hidden"  class="mobile1" value="{$vo.mobile}">
                        </li>

                    <else />
                         <li style="overflow: hidden;  zoom: 1; display: none" class="dis_none li_add">
                             <a href="javascript:void (0);" onclick="getCity(this)" style="float: left" class="li_a">{$vo.realname} {$vo.prov}</a><p style="float: left" class="li_p">{$vo.realname} <span class="addre"> {$vo.prov} {$vo.city} {$vo.dist} {$vo.address}</span><p></p><p style="float: right; color: #005EA7;"><a href="javascript:void (0);" onclick="addr_edite({$vo.id})">编辑</a></p>
                             <input type="hidden"  class="realname1" value="{$vo.realname}"><input type="hidden"  class="mobile1" value="{$vo.mobile}">
                         </li>
                </if>
            </foreach>
        </ul>
        <!-- 一开始操作的时候里面默认的值就是每个值 -->

        <input type="hidden" name="user_address" value="{$res_ad['res_ad']['addr_alone']}" id="user_address" mustAddress="1">
        <input type="hidden"  class="realname" name="realname" value="{$res_ad['res_ad']['realname']}"  	 mustAddress="1"/>
        <input type="hidden"  class="mobile" name="mobile" value="{$res_ad['res_ad']['mobile']}"  			 mustAddress="1"/>
        <input type="hidden"  class="pay_style" id="pay_style" name="pay_style" value="1"/>

        <div style="clear: both;"></div>

        <div style="line-height: 40px;"><a href="javascript:void (0);" onclick="address_more()">更多地址</a> <input type="hidden" value="1" id="ad_more"></div>
        <h3><span class="size14 bold left">支付方式</span></h3>
        <ul class="address">
            <li>
				<a href="javascript:;"  class="hover pay_statue">支付宝支付</a>
                <a href="javascript:;"  class="pay_statue">微信支付</a>
			</li>
        </ul>
        <h3><span class="size14 bold left">产品详情</span></h3>
        <ul class="commodity">
            <foreach name="list.goods_info" item="vo" >
                <li>
                        <img src="{$vo.pic_url}" width="80" height="80" class="left">
                        <span class="name left" style="height: 60px;">
                            <p>{$vo.title}<br/>套餐：<if condition="!empty($vo['taocan_name'])"> {$vo['taocan_name']}<else/> 无</if></p>
                            <p style="line-height: 24px;">{$vo.chufa_address}</p>
                            <p style="line-height: 24px;">{$vo.chufa_date}</p>
                        </span>
                    <span class="bold red size14 price left">￥{$vo.price_new}</span>
                    <span class="gray">x{$vo.goods_num}<br/>送: {$vo.fanli_jifen} 积分</span>
                </li>
                    <input type="hidden" name="pic_url[]" value="{$vo.pic_url}">
                    <input type="hidden" name="goods_title[]" value="{$vo.title}">
                    <input type="hidden" name="price_new[]" value="{$vo.price_new}">
                    <input type="hidden" name="id[]" value="{$vo.id}">
                    <input type="hidden" name="goods_num[]" value="{$vo.goods_num}">
                    <input type="hidden" name="type[]" value="{$vo.type}">

                    <input type="hidden" name="taocan_name[]" value="{$vo.taocan}">
                    <input type="hidden" name="fanli_jifen[]" value="{$vo.fanli_jifen}">
                    <input type="hidden" name="yunfei" value="{$youfei|default=0}">

                    <input type="hidden" name="chufa_address[]" value="{$vo.chufa_address}">
                    <input type="hidden" name="chufa_date[]" value="{$vo.chufa_date}">

                    商品ID: {$vo.id} <input type="hidden" name="checkbox[]" value="{$vo.id}">

            </foreach>
                 </ul>
                 <input type="hidden" name="order_type" value="{$order_type}">
        <p style="margin-bottom:10px;">添加订单备注</p>
        <p class="prompt"><input type="text" placeholder="限45个字 （定制类商品，请将购买需求在备注中做详细说明）" class="order_remarks" name="order_remarks"><span class="gray">提示：请勿填写有关支付、收货、发票方面的信息</span></p>
    </div>
</div>
<!-- 结算 -->
<div class="Billing">
    <ul>
        <li><b class="right Billing-Money">￥{$goods_info.zong|default=0}</b><span class="right"><span class="red">{$goods_info.count_goods}</span> 件商品，总商品金额：</span>
        </li>
        <li><b class="Billing-Money right">￥{$youfei|default=0}</b><span class="right Shipment">运费：</span></li>
    </ul>
    <ul class="Handle">
        <li><b class="right Billing-Money red size20" id='pay_sum'>￥{$price_sum}</b><span class="right">应付总额：</span></li>
        <li class="gray">寄送至：<span class="gray_addr">{$data_alone['addr_alone']}</span>  收货人：<span class="gray_realname">{$data_alone['realname']}</span> <span class="gray_mobile">{$data_alone['mobile']}</span></li>
		
		<!--积分模块-->

		<!--购物订单-->
			<IF condition="$grade eq '合伙人'">
			 <li><span><span style='font-weight:bold'>积分可用余额:</span>{$integral['add_jf_limit']}</span> &nbsp;<span class="Shipment">积分账户支付：<input type="hidden" id="jfa" name="jfa" value='0'></span>
					<div class="right Billing-jifen2" >
						<button class="Billing-button3" type="button" onclick="jianNum2()">-</button><input type="text" id="jfb" name="jfb" value='0'><button type="button" class="Billing-button3" onclick="addNum2()">+</button>
					</div>
			 </li>
			<ELSE/>
				<li><span><span style='font-weight:bold'>积分可用余额:</span>{$integral['add_jf_limit']}</span> &nbsp;<span class= "Shipment">积分A账户支付：</span>
					<div class="right Billing-jifen1">
						<button class="Billing-button3" type="button" onclick="jianNum1()">-</button><input type="text" onkeyup='clearJf()' id="jfa" name="jfa" value='0'><button type="button" class="Billing-button3" onclick="addNum1()">+</button>
					</div>
			 </li>
			 <li><span><span style='font-weight:bold'>积分可用余额:</span>{$integral['add_jf_currency']}</span> &nbsp;<span class="Shipment">积分B账户支付：</span>
					<div class="right Billing-jifen2" >
						<button class="Billing-button3" type="button" onclick="jianNum2()">-</button><input type="text" onkeyup='clearJf()' id="jfb" name="jfb" value='0'><button type="button" class="Billing-button3" onclick="addNum2()">+</button>
					</div>
			 </li>
			</IF>
<div style="font-size:16px; color:#F00; margin-top:10px;">温馨提示：积分兑换商品至少支付1元人民币</div>
	</ul>
	<div><input type='hidden' value="{$jfa}" id="jf1"><input type="hidden" value="{$jfb}" id='jf2'></div>
	<div><input type='hidden' value="{$city_inp}" id="city_inp"></div>
    <input type="hidden" name="price_sum" value="{$price_sum}">
    <input type="hidden" name="orders_num" value="{$Think.session.orders_number}">
	<!-- <input type="hidden" name="use_jf_currency" value="{$jf_b}">
    <input type="hidden" name="use_jf_limit" value="{$jf_a}"> -->


<a class="submit left" href="{:U('Index/index')}" style="width:200px;">返回首页</a>

<button class="submit right" style="border: none;">支付</button>

</div>
</form>

<!-- 底部 -->
<div class="bottom">
    <p>
        <a href="#">关于我们</a>
        <span>|</span>
        <a href="#"> 联系我们</a>
        <span>|</span>
        <a href="#">人才招聘</a>
        <span>|</span>
        <a href="#"> 商家入驻</a>
        <span>|</span>
        <a href="#"> 广告服务</a>
        <span>|</span>
        <a href="#">  友情链接</a>
        <span>|</span>
        <a href="#">销售聪明</a>
        <span>|</span>
        <a href="#">掌掌社区</a>
        <span>|</span>
        <a href="#">掌掌公益</a>
        <span>|</span>
        <a href="#">English Site</a>
    </p>
</div>
<script type="text/javascript">
	var urlEdit = "{:U('Cart/addr_edite')}";
	var urlAdd	= "{:U('Cart/addr_add')}";
</script>
<script type="text/javascript" src="__PUBLIC__/Home/js/order/order.js"></script>
</body>
</html>
